-
Notifications
You must be signed in to change notification settings - Fork 27.3k
Update component-router.ngdoc #14613
Conversation
the id was missing, heroId was unused
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed, please reply here (e.g.
|
1 similar comment
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed, please reply here (e.g.
|
I signed it! |
CLAs look good, thanks! |
1 similar comment
CLAs look good, thanks! |
this.gotoHeroes = function() { | ||
var heroId = this.hero && this.hero.id; | ||
this.$router.navigate(['HeroList']); | ||
this.$router.navigate(['HeroList', {id: heroId}]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, this is used (and explained) a couple of sections below. Here we should not use heroId
.
If anything, we could remove the var heroId = ...
line.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gkalpak I agree, the better solution would be to remove the var heroId = ...
line. I try to change my pull-request.
Remove 'var heroId = ...' as suggested by @gkalpak
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
fix typo in docs
What is the current behavior? (You can also link to an open issue here)
fix docs only
What is the new behavior (if this is a feature change)?
fix docs only
Does this PR introduce a breaking change?
No
Please check if the PR fulfills these requirements
Other information:
The id was missing, heroId was unused